#pragma once

#include "Functions.h"
#include "Vector2.h"
#include "Math.h"

namespace BAA
{

	class FunctionP2LinearDistance: public FunctionP2
	{
	public:

		FunctionP2LinearDistance(std::string name, Vector2 functionRange): FunctionP2(name), range(functionRange)
		{
		}

		float calculate(float valueA, float valueB)
		{
			return MathHelper::clamp(&range, (valueA-valueB));
		}


	protected:
		Vector2 range;


	};
}

